package cqie.frame.entity;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;

/**
 * 评教任务(EvaluateTask)表实体类
 *
 * @author makejava
 * @since 2021-10-09 11:04:27
 */
@SuppressWarnings("serial")
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("evaluate_task")
@ApiModel(description = "评价任务表")
public class EvaluateTask extends Model<EvaluateTask> {
    //主键
    @TableId(value = "id",type = IdType.AUTO)
    @TableField(value = "id")
    @ApiModelProperty(value = "ID")
    private Long id;
    //评教任务名称
    @TableField(value = "name")
    @ApiModelProperty(value = "评教任务名称")
    private String name;
    //开始日期
    @ApiModelProperty(value = "开始日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    @TableField("startDate")
    private Date startDate;
    //截至日期
    @ApiModelProperty(value = "截至日期")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    @TableField("endDate")
    private Date endDate;
    //状态(0:正常 1:禁用)
    @ApiModelProperty(value = "状态(0:正常 1:禁用)")
    private Integer status;

    /**
     * 获取主键值
     *
     * @return 主键值
     */
    @Override
    protected Serializable pkVal() {
        return this.id;
    }
    }

